<?php

/**
 *  错误控制器
 *
 * @author: xiadx
 * @date: ${YEAR}-${MONTH}-${DAY}
 * @version: $Id: Error.php 12704 2015-11-23 12:47:16Z zdw $
 */
class ErrorController extends Yaf_Controller_Abstract
{

    public function errorAction($exception)
    {
/*        if ($exception->getCode() == 516 && !headers_sent())
        {
            header('HTTP/1.1 404 Not Found', TRUE, 404);
            header('status: 404 Not Found', TRUE, 404);
//            exit();
            return FALSE;
        }*/
        $html = Kohana_Exception::handler($exception);
        echo $html;
//		$this->getView()->assign("exception", $exception);
        return FALSE;
    }
}
